<template>
  <div class="communitypic">
    <img :src="datas.pic_url" alt="" />
    <div class="communitypic-font">
      <h1>{{datas.theme_title}}</h1>
      <div class="font-main">       
        <p>{{datas.theme_content}}</p>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      datas:[]
    }
  },
  created(){
    this.$axios.get(`/api/users/getEssayByThemeId?theme_id=${this.$route.query.id}`).then((res)=>{
      this.datas = res.data.results[0]
    })
  }
};
</script>

<style>
.communitypic {
  margin: 0 auto;
  margin-right:20px;
  padding-bottom:20px;
}
.communitypic-font {
    width: 500px;
    margin-bottom: 50px;
}
.communitypic img {
  width: 450px;
  height: 550px;
}
</style>